<?php
class Common extends CI_Controller {
	public function unauthorized() 
    {
        $template_data['title'] = "Acceso no autorizado"; // Capitalize first letter
        $template_data['content'] = $this->load->view('common/unauthorized', array(), True);
        $this->load->view('templates/main', $template_data);
	}
    
    public function home() 
    {
        // Authetication succeed, go to private area
		$session_data = $this->session->userdata('logged_in');
		$data['username'] = $session_data['username'];
        $template_data['title'] = 'Sesion iniciada';
        $template_data['content'] = $this->load->view('common/home', $data, True);
        $this->load->view('templates/main', $template_data);
    }
}
?>
